
interface Current{
    name: string
    degree: number
    phone: string
}


type AppAttrToObjectTwo<E, G extends string, D> = {
    [Y in keyof E | G] : Y extends keyof E ? E[Y] : D
}

type addProps = AppAttrToObjectTwo<Current, "height", number>

type Modules = {
    menu: {
        onSelect: () =>void,
        add: () => void
    },
    tree: {
        delete: () => string
    }
}

type GetSpliceKeys<T> = {
    [K in keyof T] :  T[K]
}


type TestSpliceKeys = GetSpliceKeys<Modules>